//
//  NotesDetailTableViewCell.m
//  Funny
//
//  Created by dllo on 15/10/31.
//  Copyright © 2015年 King. All rights reserved.
//

#import "NotesDetailTableViewCell.h"


@implementation NotesDetailTableViewCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        self.imgView = [[UIImageView alloc]init];
        [self.contentView addSubview:self.imgView];
        
        self.TEXTLebel = [[UILabel alloc]init];
        [self.contentView addSubview:self.TEXTLebel];
        self.TEXTLebel.numberOfLines = 0;
        self.TEXTLebel.font = [UIFont systemFontOfSize:14];
        self.TEXTLebel.lineBreakMode = NSLineBreakByCharWrapping;
        
        self.pic = [[UIImageView alloc]init];
        self.pic.image = [UIImage imageNamed:@"image.png"];
        [self.imgView addSubview:self.pic];
        
        self.titleLabel = [[UILabel alloc]init];
        self.titleLabel.font = [UIFont systemFontOfSize:16];
        [self.pic addSubview:self.titleLabel];
        self.titleLabel.textColor = [UIColor whiteColor];
        
        self.scoreLabel = [[UILabel alloc]init];
        self.scoreLabel.font = [UIFont systemFontOfSize:14];
        [self.pic addSubview:self.scoreLabel];
        self.scoreLabel.textColor = [UIColor whiteColor];
        self.scoreLabel.textAlignment = NSTextAlignmentRight;
    }
    return self;
}
- (void)layoutSubviews
{
    [super layoutSubviews];
    self.imgView.frame = CGRectMake(10*W, 10*H, 355*W, 180*H);
    self.pic.frame = CGRectMake(0, 120*H, 355*W, 40*H);
    self.titleLabel.frame = CGRectMake(15*W, 15*H, 200*W, 30*H);
    self.scoreLabel.frame = CGRectMake(240*W, 15*H, 105*W, 30*H);
}

- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
